Optimal. Leaf size=33 \[ \frac{3 x}{8 a}+\frac{\sin (x) \cos ^3(x)}{4 a}+\frac{3 \sin (x) \cos (x)}{8 a} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.055304, antiderivative size = 33, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 16, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.188, Rules used = {3175, 2635, 8} \[ \frac{3 x}{8 a}+\frac{\sin (x) \cos ^3(x)}{4 a}+\frac{3 \sin (x) \cos (x)}{8 a} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3175
Rule 2635
Rule 8
Rubi steps
\begin{align*} \int \frac{\cos ^6(x)}{a-a \sin ^2(x)} \, dx &=\frac{\int \cos ^4(x) \, dx}{a}\\ &=\frac{\cos ^3(x) \sin (x)}{4 a}+\frac{3 \int \cos ^2(x) \, dx}{4 a}\\ &=\frac{3 \cos (x) \sin (x)}{8 a}+\frac{\cos ^3(x) \sin (x)}{4 a}+\frac{3 \int 1 \, dx}{8 a}\\ &=\frac{3 x}{8 a}+\frac{3 \cos (x) \sin (x)}{8 a}+\frac{\cos ^3(x) \sin (x)}{4 a}\\ \end{align*}
Mathematica [A] time = 0.0030953, size = 26, normalized size = 0.79 \[ \frac{\frac{3 x}{8}+\frac{1}{4} \sin (2 x)+\frac{1}{32} \sin (4 x)}{a} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.04, size = 40, normalized size = 1.2 \begin{align*}{\frac{\tan \left ( x \right ) }{4\,a \left ( \left ( \tan \left ( x \right ) \right ) ^{2}+1 \right ) ^{2}}}+{\frac{3\,\tan \left ( x \right ) }{8\,a \left ( \left ( \tan \left ( x \right ) \right ) ^{2}+1 \right ) }}+{\frac{3\,\arctan \left ( \tan \left ( x \right ) \right ) }{8\,a}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.50521, size = 50, normalized size = 1.52 \begin{align*} \frac{3 \, \tan \left (x\right )^{3} + 5 \, \tan \left (x\right )}{8 \,{\left (a \tan \left (x\right )^{4} + 2 \, a \tan \left (x\right )^{2} + a\right )}} + \frac{3 \, x}{8 \, a} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.92784, size = 62, normalized size = 1.88 \begin{align*} \frac{{\left (2 \, \cos \left (x\right )^{3} + 3 \, \cos \left (x\right )\right )} \sin \left (x\right ) + 3 \, x}{8 \, a} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] time = 30.2134, size = 473, normalized size = 14.33 \begin{align*} \frac{3 x \tan ^{8}{\left (\frac{x}{2} \right )}}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} + \frac{12 x \tan ^{6}{\left (\frac{x}{2} \right )}}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} + \frac{18 x \tan ^{4}{\left (\frac{x}{2} \right )}}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} + \frac{12 x \tan ^{2}{\left (\frac{x}{2} \right )}}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} + \frac{3 x}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} - \frac{10 \tan ^{7}{\left (\frac{x}{2} \right )}}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} + \frac{6 \tan ^{5}{\left (\frac{x}{2} \right )}}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} - \frac{6 \tan ^{3}{\left (\frac{x}{2} \right )}}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} + \frac{10 \tan{\left (\frac{x}{2} \right )}}{8 a \tan ^{8}{\left (\frac{x}{2} \right )} + 32 a \tan ^{6}{\left (\frac{x}{2} \right )} + 48 a \tan ^{4}{\left (\frac{x}{2} \right )} + 32 a \tan ^{2}{\left (\frac{x}{2} \right )} + 8 a} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.0963, size = 49, normalized size = 1.48 \begin{align*} \frac{3 \, \arctan \left (\tan \left (x\right )\right )}{8 \, a} + \frac{\frac{3 \, \tan \left (x\right )^{3}}{a} + \frac{5 \, \tan \left (x\right )}{a}}{8 \,{\left (\tan \left (x\right )^{2} + 1\right )}^{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]